#ifndef _GIMBAL_CTRL_H_
#define _GIMBAL_CTRL_H_

#include "config.h"
#include <pthread.h>
#include <semaphore.h>

typedef struct s_gimbal_ctrl
{
    int             pitch_pulse;
    int             yaw_pulse;
    char            order[10];
    pthread_mutex_t lock;
    sem_t           sem;
} gimbal_ctrl_t;

/* 告知线程有控制信号 */
void ctrl_notice_update(void);

/* 处理运动控制命令 */
void *gimbal_control_process(void *arg);

extern gimbal_ctrl_t gimbal_ctrl;

#endif